#include <stdio.h>
#include "libdwinport.h"

int main(void)
{
	dwInit();
	dwWriteSingleVar(VAR_PARTNUM_ADDR,1);
	dwWriteSingleVar(VAR_COLNUM_ADDR,2);
	dwWriteSingleVar(VAR_TEMP_ADDR,28);
	while(1){
		//灯光
		if(dw_var_get(VAR_LIGHT_ADDR)->change){
			dw_var_read(VAR_LIGHT_ADDR,&value,VAR_LIGHT_LENGTH);
			if(value){
				LED_LIGHT_ON;
			}else{
				LED_LIGHT_OFF;
			}
			dw_var_get(VAR_LIGHT_ADDR)->change = 0;
		}
	}

